package com.example.demo.factoryMode.simpleFactpry;

public class Consumer {

    public static void main(String[] args) {
//        Car car = new BaoMa();
//        Car car1 = new AoDi();

        Car car = CarFactory.getCar("宝马");
        Car car1 = CarFactory.getCar("奥迪");

        car.name();
        car1.name();

    }

}
